package com.key.gradle.test.servlet3;

import org.springframework.web.servlet.support.AbstractAnnotationConfigDispatcherServletInitializer;

import com.key.gradle.test.config.SpringRootConfig;
import com.key.gradle.test.config.SpringWebConfig;

public class Servlet3WebInitializer extends AbstractAnnotationConfigDispatcherServletInitializer {

	@Override
	protected Class<?>[] getRootConfigClasses() {
		return new Class[] { SpringRootConfig.class };
	}

	@Override
	protected Class<?>[] getServletConfigClasses() {
		return new Class[] { SpringWebConfig.class };
	}

	@Override
	protected String[] getServletMappings() {
		return new String[] { "/" };
	}
	
//	@Override
//    public Collection<JspPropertyGroupDescriptor> getJspPropertyGroups() {
//		super.
//        Collection<JspPropertyGroupDescriptor> c = new ArrayList<JspPropertyGroupDescriptor>();
//        JspPropertyGroupDescriptorImpl pgDescriptor = new JspPropertyGroupDescriptorImpl();
//        pgDescriptor.setIsXml(Boolean.TRUE.toString());
//        pgDescriptor.getUrlPattern().add("/js/generated/*");
//        pgDescriptor.setElIgnored(Boolean.FALSE.toString());
//        pgDescriptor.setPageEncoding("UTF-8");
//        c.add(pgDescriptor);
//        return null;
//    }
	
}
